<template>
        <div>
            <div id="chartSix" ref="chartSix"></div>
            <el-row :gutter="20">
                <el-col :span="12">
                   
                </el-col>
            </el-row>
        </div>
    </template>
    <script>
    export default {
        name: "echartChart",
        created() {
           
        },
        mounted() {
            this.initCharts();
        },
        updated() {},
        data() {
            return {
                
            };
        },
     
        methods: {
            //设置图表
            initCharts() {
                let that = this;
                
                let chartSix = that.$echarts.init(that.$refs.chartSix);
                //     that.$refs.chartSix.style.width = "200px";
                //    that.$refs.chartSix.height = "300px";
                // console.log(chartSix);
                let legrndData = [];
                for (let i = 0; i < this.data.length; i++) {
                    legrndData.push(this.data[i].name);
                }
                // console.log("legrndData");
                // console.log(legrndData);
                let option = {
                    tooltip: {
                        trigger: "item",
                    },
                    
                    title: [
                        {
                            left: "center",
                            text: "日结数量",
                        },
                    ],
                    xAxis: {
    type: 'category',
    data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
  },
  yAxis: {
    type: 'value'
  },
  series: [
    {
      data: [120, 200, 150, 80, 70, 110, 130],
      type: 'bar'
    }
  ]
                };
                // console.log(option);
                chartSix.setOption(option);
            },
        },
    };
    </script>
    <style lang="scss" scoped>
    #chartSix {
        width: 580px;
        height: 355px;
    }
    </style>